home *** CD-ROM | disk | FTP | other *** search
/ The Fatted Calf / The Fatted Calf.iso / Applications / Misc / Crossword / Source / PlainSquare.h < prev    next >
Text File  |  1992-10-11  |  1KB  |  63 lines

  1. /*
  2.  
  3. File PlainSquare.h
  4.  
  5. Squares are the variables that guide the search.  This file implements simple squares for plain depth first search.
  6.  
  7. */
  8.  
  9. #import <objc/Object.h>
  10.  
  11. #import "CrosswordSquare.h"
  12. #import "Dictionary.h"
  13.  
  14.  
  15. /* ————————————————————————————————————————————————————————————————————————————  */
  16.  
  17.  
  18. #define HILIGHT        1 << 0
  19.  
  20.  
  21. /* ————————————————————————————————————————————————————————————————————————————  */
  22.  
  23.  
  24. typedef struct {
  25.                     id        word;
  26.                     int        i;
  27.     } wordPosition;
  28.  
  29.  
  30. /* ————————————————————————————————————————————————————————————————————————————  */
  31.  
  32.  
  33. @interface PlainSquare:Object
  34. {
  35.     id                    puzzle;
  36.     id                    words;
  37.     CrosswordSquare        * cell;
  38.     float                efficiency;
  39.     int                    count [LETTERS];
  40.     char                letter;
  41.     int                    tried;
  42.     int                    status;
  43. }
  44.  
  45. - (float) efficiency;
  46. - initPuzzle: (id) thePuzzle  cell: (id) theCell;
  47. - free;
  48. - addToWord: (id) word  at: (int) i;
  49. - startOver;
  50. - setStatus: (int) flag;
  51. - clearStatus: (int) flag;
  52. - hilight;
  53. - unhilight;
  54. - adjustColor;
  55. - (BOOL) fillNext;
  56. - erase;
  57. - clear;
  58. - show;
  59. - (char) chooseLetter;
  60. - setLetter: (char) theLetter;
  61. - update;
  62.  
  63. @end